package com.jeff.android.lab.android.lifecycle.viewmodel;

import android.app.Application;

import androidx.annotation.NonNull;
import androidx.lifecycle.AndroidViewModel;
import androidx.lifecycle.MutableLiveData;

import java.util.List;

public abstract class AbstractViewModel<T> extends AndroidViewModel {

    protected MutableLiveData<List<T>> mLiveData;

    public AbstractViewModel(@NonNull Application application) {
        super(application);
        mLiveData = new MutableLiveData<>();
    }

    public MutableLiveData<List<T>> getLiveData() {
        return mLiveData;
    }

    public abstract void loadData();
}
